package com.antd.common.log.fegin;

import com.antd.admin.api.entity.SysLog;
import com.antd.admin.api.entity.SysUser;
import com.antd.common.core.util.R;
import com.antd.common.log.fegin.factory.RemoteLogFallBackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * TODO
 *
 * @author 子丶沫
 * @version 1.0
 * @date 2020/11/18 17:57
 */
@FeignClient(contextId = "remoteLogService",value = "antd-admin-server",fallbackFactory = RemoteLogFallBackFactory.class)
public interface RemoteLogService {
    /**
     * 保存日志
     * @param sysLog
     * @return
     */
    @PostMapping("/log")
    R<Object> saveLog(@RequestBody SysLog sysLog);
}
